/*
 * File:   vfd.h
 * Author: Marcel
 *
 * Created on 19. Juli 2012, 02:54
 */

#ifndef VFD_H
#define	VFD_H



#define VFD_DATA LATB
#define VFD_SEL LATAbits.LATA3
#define VFD_BSY PORTAbits.RA4
#define VFD_WR	LATAbits.LATA5

#define VFD_WIDTH 20
#define VFD_HEIGHT 2
#define VFD_SIZE 40

#define MULTIPLIER 100.0f  // Decimal places of float to string conversion

void vfd_init(void);
void vfd_clear(void);
void vfd_pos(unsigned char pos);
void vfd_pos_xy(unsigned char x, unsigned char y);
void vfd_putc(unsigned char c);
void vfd_puts(char* string);
void vfd_putrs(const rom char* string);
void vfd_puttemp(unsigned int f, unsigned char pos_x, unsigned char pos_y);
void vfd_puti(int i);
void vfd_putb(unsigned char c);
void vfd_puthex(unsigned char c);
void vfd_putcmd(unsigned char cmd);
void vfd_draw(void);


#endif	/* VFD_H */


